package com.lu.model;

import java.util.List;

/**
 * @program Elasticsearch
 * @description:    es文档批量更新操作，响应数据解析
 * @author: zhanglu
 * @create: 2020-04-30 09:31:00
 */
public class EsUpdaeBatchDocAction {


    /**
     * took : 216
     * errors : false
     * items : [{"index":{"_index":"ss","_type":"s","_id":"AXHIsXZ519NvNolaKFgm","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"ss","_type":"s","_id":"AXHIsXZ519NvNolaKFgn","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"ss","_type":"s","_id":"AXHIsXZ519NvNolaKFgo","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"ss","_type":"s","_id":"AXHIsXZ519NvNolaKFgp","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}}]
     */

    private int took;
    private boolean errors;
    private List<ItemsBean> items;

    public int getTook() {
        return took;
    }

    public void setTook(int took) {
        this.took = took;
    }

    public boolean isErrors() {
        return errors;
    }

    public void setErrors(boolean errors) {
        this.errors = errors;
    }

    public List<ItemsBean> getItems() {
        return items;
    }

    public void setItems(List<ItemsBean> items) {
        this.items = items;
    }

    public static class ItemsBean {
        /**
         * index : {"_index":"ss","_type":"s","_id":"AXHIsXZ519NvNolaKFgm","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}
         */

        private EsUpdaeDocAction index;

        public EsUpdaeDocAction getIndex() {
            return index;
        }

        public void setIndex(EsUpdaeDocAction index) {
            this.index = index;
        }

    }
}
